package cn.fjsay.java.demo8;

public class Test {
    public static void main(String[] args) {
        AbstractShape shape1 = new Rectangle(5, 3);
        AbstractShape shape2 = new Circle(2.5);

        shape1.draw();
        System.out.println("面积: " + shape1.area());

        shape2.draw();
        System.out.println("面积: " + shape2.area());
    }
}
